Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to Go 1.22.5 #40082

Merged
merged 18 commits into from
Jul 23, 2024
Merged

Update to Go 1.22.5 #40082

merged 18 commits into from
Jul 23, 2024

Conversation

blakerouse
Copy link
Contributor

@blakerouse blakerouse commented Jul 2, 2024

Proposed commit message

Update to the latest version of golang 1.22.5.

Checklist

  • My code follows the style guidelines of this project
  • I have commented my code, particularly in hard-to-understand areas
  • [ ] I have made corresponding changes to the documentation
  • [ ] I have made corresponding change to the default configuration files
  • I have added tests that prove my fix is effective or that my feature works
  • I have added an entry in CHANGELOG.next.asciidoc or CHANGELOG-developer.next.asciidoc.

@blakerouse blakerouse added backport-skip Skip notification from the automated backport with mergify Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team labels Jul 2, 2024
@blakerouse blakerouse self-assigned this Jul 2, 2024
@blakerouse blakerouse requested review from a team as code owners July 2, 2024 22:05
@elasticmachine
Copy link
Collaborator

Pinging @elastic/elastic-agent-control-plane (Team:Elastic-Agent-Control-Plane)

@botelastic botelastic bot added needs_team Indicates that the issue/PR needs a Team:* label and removed needs_team Indicates that the issue/PR needs a Team:* label labels Jul 2, 2024
Copy link
Contributor

mergify bot commented Jul 2, 2024

This pull request is now in conflicts. Could you fix it? 🙏
To fixup this pull request, you can check out it locally. See documentation: https://help.github.com/articles/checking-out-pull-requests-locally/

git fetch upstream
git checkout -b go-1.22 upstream/go-1.22
git merge upstream/main
git push upstream go-1.22

@blakerouse
Copy link
Contributor Author

CI seems unable to find the mage command for this change. I see that the CI job is installing golang version because its not present on the VM base image, that might be the issue and why mage is not present?

@jlind23
Copy link
Collaborator

jlind23 commented Jul 3, 2024

@elastic/ingest-eng-prod can someone please assist here with the golang version update?

@dliappis
Copy link
Contributor

dliappis commented Jul 3, 2024

CI seems unable to find the mage command for this change. I see that the CI job is installing golang version because its not present on the VM base image, that might be the issue and why mage is not present?

Indeed, the images falls back to installing the missing go, if not prebundled in cases of PR like this one, but we also need to install mage too. Raising a fix soon.

@dliappis
Copy link
Contributor

dliappis commented Jul 3, 2024

CI seems unable to find the mage command for this change. I see that the CI job is installing golang version because its not present on the VM base image, that might be the issue and why mage is not present?

Indeed, the images falls back to installing the missing go, if not prebundled in cases of PR like this one, but we also need to install mage too. Raising a fix soon.

A new Windows 2022 image got built recently (see pr). I clicked retry to the heartbeat win 2022 job which seems to be moving forwards (mage got installed: https://buildkite.com/elastic/heartbeat/builds/6086#019078c4-30ea-4ba4-ac7d-30e353db62c0/108-109)

@dliappis
Copy link
Contributor

dliappis commented Jul 3, 2024

CI seems unable to find the mage command for this change. I see that the CI job is installing golang version because its not present on the VM base image, that might be the issue and why mage is not present?

Indeed, the images falls back to installing the missing go, if not prebundled in cases of PR like this one, but we also need to install mage too. Raising a fix soon.

A new Windows 2022 image got built recently (see pr). I clicked retry to the heartbeat win 2022 job which seems to be moving forwards (mage got installed: https://buildkite.com/elastic/heartbeat/builds/6086#019078c4-30ea-4ba4-ac7d-30e353db62c0/108-109)

This has been successful, so I've since rebuilt all Windows custom Beats images to support mage installation as a fallback and clicked retry on all failed jobs ^^

@blakerouse
Copy link
Contributor Author

I believe that go 1.22 adjusts how its represents a regex into a string. See commit for the changes I made to the tests, I don't see any really issues with these changes in the test. 88964ad

@oakrizan oakrizan added :Windows :integrations macOS Enable builds in the CI for darwin testing arm Enable builds in the CI for ARM testing kubernetes Enable builds in the CI for kubernetes aws Enable builds in the CI for aws cloud testing labels Jul 15, 2024
@oakrizan
Copy link
Contributor

/test

@dliappis
Copy link
Contributor

dliappis commented Jul 15, 2024

Note we chatted with @oakrizan about the failing x-pack/metricbeat: AWS Tests and at least as of 4 days ago they used be successful: https://buildkite.com/elastic/beats-xpack-metricbeat/builds/5078#0190a2f4-ee9d-4b99-8311-924166b10128

So it's unclear whether they are affected by this PR, or something else that's changed during the last few days.

UPDATE: They aren't related to this PR; see #40242

@dliappis
Copy link
Contributor

Additionally there appears to be general flakiness with macOS arm64 CI tests; usually the four automatic buildkite retries help, but lately seems they don't; the issue is tracked in #40237

@ycombinator
Copy link
Contributor

Thanks for your help and the detailed RCA, @shmsr. Back over to you @blakerouse.

@blakerouse
Copy link
Contributor Author

@shmsr Thank you so much for the help and detailed analysis on this issue, I really appreciate it.

I have updated the PR with latest main, lets see if it fully passes.

@jlind23
Copy link
Collaborator

jlind23 commented Jul 23, 2024

@pierrehilbert @cmacknz after chatting with @blakerouse we do need to backport this to 8.15 in order to align go versions in Agent and Beats.
Shouldn't we bypass requirements?

@cmacknz
Copy link
Member

cmacknz commented Jul 23, 2024

I'm fine to force merge this and backport to 8.15, we just need the new conflict to be resolved first.

@blakerouse
Copy link
Contributor Author

I have fixed the conflict, once we get green again lets force merge this.

@cmacknz cmacknz enabled auto-merge (squash) July 23, 2024 20:41
@cmacknz cmacknz disabled auto-merge July 23, 2024 21:03
@cmacknz cmacknz merged commit c0f8ae3 into elastic:main Jul 23, 2024
199 checks passed
mergify bot pushed a commit that referenced this pull request Jul 23, 2024
* Update to go 1.22.4.

* Link to PR.

* Fix bad merge.

* Fix some regex.

* Fix config_test.go

* Comment out ping.

* Update to go 1.22.5.

* Un-comment code.

* Update go.mod.

* Add encrypt=false to mssql py test.

* Make CI happy

* Fix NOTICE.txt.

---------

Co-authored-by: subham sarkar <[email protected]>
Co-authored-by: Julien Lind <[email protected]>
(cherry picked from commit c0f8ae3)
mergify bot pushed a commit that referenced this pull request Jul 23, 2024
* Update to go 1.22.4.

* Link to PR.

* Fix bad merge.

* Fix some regex.

* Fix config_test.go

* Comment out ping.

* Update to go 1.22.5.

* Un-comment code.

* Update go.mod.

* Add encrypt=false to mssql py test.

* Make CI happy

* Fix NOTICE.txt.

---------

Co-authored-by: subham sarkar <[email protected]>
Co-authored-by: Julien Lind <[email protected]>
(cherry picked from commit c0f8ae3)

# Conflicts:
#	auditbeat/module/file_integrity/config_test.go
#	dev-tools/mage/crossbuild.go
#	go.mod
#	libbeat/docs/version.asciidoc
#	libbeat/processors/actions/drop_fields_test.go
#	metricbeat/Dockerfile
cmacknz pushed a commit that referenced this pull request Jul 24, 2024
* Update to go 1.22.4.

* Link to PR.

* Fix bad merge.

* Fix some regex.

* Fix config_test.go

* Comment out ping.

* Update to go 1.22.5.

* Un-comment code.

* Update go.mod.

* Add encrypt=false to mssql py test.

* Make CI happy

* Fix NOTICE.txt.

---------

Co-authored-by: subham sarkar <[email protected]>
Co-authored-by: Julien Lind <[email protected]>
(cherry picked from commit c0f8ae3)

Co-authored-by: Blake Rouse <[email protected]>
blakerouse pushed a commit that referenced this pull request Jul 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
arm Enable builds in the CI for ARM testing aws Enable builds in the CI for aws cloud testing backport-7.17 Automated backport to the 7.17 branch with mergify backport-8.15 Automated backport to the 8.15 branch with mergify :integrations kubernetes Enable builds in the CI for kubernetes macOS Enable builds in the CI for darwin testing Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team :Windows
Projects
None yet
Development

Successfully merging this pull request may close these issues.